#ifndef STICK_H_INCLUDED
#define STICK_H_INCLUDED

#include "Environment.h"
#include "PointMass.h"
#include "Vector.h"

namespace BlobSalladDS
{
	class Stick
	{
		private:
			double length;
			double lengthSquared;
			PointMass *pointMassA;
			PointMass *pointMassB;
			Vector *delta;

			double pointMassDist(PointMass &pointMassA, PointMass &pointMassB);
		public:
			Stick(PointMass *pointMassA, PointMass *pointMassB);
			PointMass *getPointMassA();
			PointMass *getPointMassB();
			void scale(double scaleFactor);
			void sc(Environment &env);
			void setForce(Vector &force);
			void addForce(Vector &force);
			void move(double dt);
			void draw(void * ctx, double scaleFactor);
	};
}

#endif // STICK_H_INCLUDED
